﻿@{
    ViewBag.Title = "报表查询";
    Layout = "~/Views/Shared/_Layout.cshtml";
}
@section ScriptAndCss{
    <link href="@Url.Content("~/Content/css/plan.css")" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="@Url.Content("~/Scripts/reportView.js")"></script>
    <style type="text/css">
        button {
            margin: 0 3px;
        }

            button[data-querytype] {
                height: 23px;
            }

        .configButton button {
            margin: 5px 14px;
            padding: 2px 8px;
        }

        .reportList {
            height: 90%;
            margin: 5px;
            border: solid 1px #95B8E7;
        }

        #searchParam > div {
            width: 33%;
            padding: 0;
        }

            #searchParam > div.one-line {
                width: 100%;
            }

                #searchParam > div.one-line > div.left {
                    width: 10%;
                }

        #searchParam .right select {
            width: 153px;
        }

        #searchParam .right input[type="text"] {
            width: 149px;
        }

        #quickAccess {
            height: 1180px;
        }

        .main_right {
            height: 1150px;
        }

        .reportListContainer {
            position: absolute;
            top: 170px;
            bottom: 0;
            width: 100%;
        }
    </style>
    <script type="text/javascript">
        isReportOrPlan = true;
        $(function () {
            $('#quickAccess').tree({
                url: '@(Url.Action("MenuList", "ReportView"))',
                onClick: function (node) {
                    var href = $.parseJSON(node.attributes).targetHref;
                    var html = $.get(href, function (res) {
                        $('#center_container').html(res);
                    });
                },

                //默认点击第一个menu
                onLoadSuccess: function (node, data) {
                    $(this).find('.tree-node').first().click();
                }

            });

            //表单重置
            $('button[type="reset"]').die('click').live('click', function () {
                var form = $(this).parents('form');

                //清空日期控件的值
                form.find('.easyui-datebox').datebox('setValue', '');
                form[0].reset();
            });
        });

        var DateFormate = function (value, row, index) {
            if (value && typeof (value) == "string") {
                return value.DateStringConvert('yyyy-MM-dd');
            }
            return value;
        };
    </script>
}

<div id="center_container" style="height: 100%; position: relative;"></div>
